﻿using System;
using System.Collections.Generic;
using System.Text;

namespace RaisingStudio.Data.SharePoint.Entities
{
    public partial class _MasterPageGallery : RaisingStudio.Data.Expressions.TableExpression, RaisingStudio.Data.Expressions.IQueryExpression<_MasterPageGallery>
    {
        #region Constructor (s) / Destructor
        /// <summary>
        /// Constructor (s) / Destructor.
        /// </summary>
        public _MasterPageGallery() : base("MasterPageGallery")
        {
        }
        #endregion
        #region Members
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _ID = "ID";
        public RaisingStudio.Data.Expressions.ColumnExpression ID { get { return _ID; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _ContentTypeId = "ContentTypeId";
        public RaisingStudio.Data.Expressions.ColumnExpression ContentTypeId { get { return _ContentTypeId; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _ContentType = "ContentType";
        public RaisingStudio.Data.Expressions.ColumnExpression ContentType { get { return _ContentType; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Created = "Created";
        public RaisingStudio.Data.Expressions.ColumnExpression Created { get { return _Created; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Author = "Author";
        public RaisingStudio.Data.Expressions.ColumnExpression Author { get { return _Author; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Modified = "Modified";
        public RaisingStudio.Data.Expressions.ColumnExpression Modified { get { return _Modified; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Editor = "Editor";
        public RaisingStudio.Data.Expressions.ColumnExpression Editor { get { return _Editor; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __HasCopyDestinations = "_HasCopyDestinations";
        public RaisingStudio.Data.Expressions.ColumnExpression _HasCopyDestinations { get { return __HasCopyDestinations; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __CopySource = "_CopySource";
        public RaisingStudio.Data.Expressions.ColumnExpression _CopySource { get { return __CopySource; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __ModerationStatus = "_ModerationStatus";
        public RaisingStudio.Data.Expressions.ColumnExpression _ModerationStatus { get { return __ModerationStatus; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __ModerationComments = "_ModerationComments";
        public RaisingStudio.Data.Expressions.ColumnExpression _ModerationComments { get { return __ModerationComments; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _FileRef = "FileRef";
        public RaisingStudio.Data.Expressions.ColumnExpression FileRef { get { return _FileRef; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _FileDirRef = "FileDirRef";
        public RaisingStudio.Data.Expressions.ColumnExpression FileDirRef { get { return _FileDirRef; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Last_x0020_Modified = "Last_x0020_Modified";
        public RaisingStudio.Data.Expressions.ColumnExpression Last_x0020_Modified { get { return _Last_x0020_Modified; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Created_x0020_Date = "Created_x0020_Date";
        public RaisingStudio.Data.Expressions.ColumnExpression Created_x0020_Date { get { return _Created_x0020_Date; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _File_x0020_Size = "File_x0020_Size";
        public RaisingStudio.Data.Expressions.ColumnExpression File_x0020_Size { get { return _File_x0020_Size; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _FSObjType = "FSObjType";
        public RaisingStudio.Data.Expressions.ColumnExpression FSObjType { get { return _FSObjType; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _PermMask = "PermMask";
        public RaisingStudio.Data.Expressions.ColumnExpression PermMask { get { return _PermMask; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _CheckedOutUserId = "CheckedOutUserId";
        public RaisingStudio.Data.Expressions.ColumnExpression CheckedOutUserId { get { return _CheckedOutUserId; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _IsCheckedoutToLocal = "IsCheckedoutToLocal";
        public RaisingStudio.Data.Expressions.ColumnExpression IsCheckedoutToLocal { get { return _IsCheckedoutToLocal; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _CheckoutUser = "CheckoutUser";
        public RaisingStudio.Data.Expressions.ColumnExpression CheckoutUser { get { return _CheckoutUser; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _FileLeafRef = "FileLeafRef";
        public RaisingStudio.Data.Expressions.ColumnExpression FileLeafRef { get { return _FileLeafRef; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _UniqueId = "UniqueId";
        public RaisingStudio.Data.Expressions.ColumnExpression UniqueId { get { return _UniqueId; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _ProgId = "ProgId";
        public RaisingStudio.Data.Expressions.ColumnExpression ProgId { get { return _ProgId; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _ScopeId = "ScopeId";
        public RaisingStudio.Data.Expressions.ColumnExpression ScopeId { get { return _ScopeId; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _VirusStatus = "VirusStatus";
        public RaisingStudio.Data.Expressions.ColumnExpression VirusStatus { get { return _VirusStatus; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _CheckedOutTitle = "CheckedOutTitle";
        public RaisingStudio.Data.Expressions.ColumnExpression CheckedOutTitle { get { return _CheckedOutTitle; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __CheckinComment = "_CheckinComment";
        public RaisingStudio.Data.Expressions.ColumnExpression _CheckinComment { get { return __CheckinComment; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _LinkCheckedOutTitle = "LinkCheckedOutTitle";
        public RaisingStudio.Data.Expressions.ColumnExpression LinkCheckedOutTitle { get { return _LinkCheckedOutTitle; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Modified_x0020_By = "Modified_x0020_By";
        public RaisingStudio.Data.Expressions.ColumnExpression Modified_x0020_By { get { return _Modified_x0020_By; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Created_x0020_By = "Created_x0020_By";
        public RaisingStudio.Data.Expressions.ColumnExpression Created_x0020_By { get { return _Created_x0020_By; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _File_x0020_Type = "File_x0020_Type";
        public RaisingStudio.Data.Expressions.ColumnExpression File_x0020_Type { get { return _File_x0020_Type; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _HTML_x0020_File_x0020_Type = "HTML_x0020_File_x0020_Type";
        public RaisingStudio.Data.Expressions.ColumnExpression HTML_x0020_File_x0020_Type { get { return _HTML_x0020_File_x0020_Type; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __SourceUrl = "_SourceUrl";
        public RaisingStudio.Data.Expressions.ColumnExpression _SourceUrl { get { return __SourceUrl; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __SharedFileIndex = "_SharedFileIndex";
        public RaisingStudio.Data.Expressions.ColumnExpression _SharedFileIndex { get { return __SharedFileIndex; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __EditMenuTableStart = "_EditMenuTableStart";
        public RaisingStudio.Data.Expressions.ColumnExpression _EditMenuTableStart { get { return __EditMenuTableStart; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __EditMenuTableEnd = "_EditMenuTableEnd";
        public RaisingStudio.Data.Expressions.ColumnExpression _EditMenuTableEnd { get { return __EditMenuTableEnd; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _LinkFilenameNoMenu = "LinkFilenameNoMenu";
        public RaisingStudio.Data.Expressions.ColumnExpression LinkFilenameNoMenu { get { return _LinkFilenameNoMenu; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _LinkFilename = "LinkFilename";
        public RaisingStudio.Data.Expressions.ColumnExpression LinkFilename { get { return _LinkFilename; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _DocIcon = "DocIcon";
        public RaisingStudio.Data.Expressions.ColumnExpression DocIcon { get { return _DocIcon; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _ServerUrl = "ServerUrl";
        public RaisingStudio.Data.Expressions.ColumnExpression ServerUrl { get { return _ServerUrl; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _EncodedAbsUrl = "EncodedAbsUrl";
        public RaisingStudio.Data.Expressions.ColumnExpression EncodedAbsUrl { get { return _EncodedAbsUrl; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _BaseName = "BaseName";
        public RaisingStudio.Data.Expressions.ColumnExpression BaseName { get { return _BaseName; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _FileSizeDisplay = "FileSizeDisplay";
        public RaisingStudio.Data.Expressions.ColumnExpression FileSizeDisplay { get { return _FileSizeDisplay; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _MetaInfo = "MetaInfo";
        public RaisingStudio.Data.Expressions.ColumnExpression MetaInfo { get { return _MetaInfo; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __Level = "_Level";
        public RaisingStudio.Data.Expressions.ColumnExpression _Level { get { return __Level; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __IsCurrentVersion = "_IsCurrentVersion";
        public RaisingStudio.Data.Expressions.ColumnExpression _IsCurrentVersion { get { return __IsCurrentVersion; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _SelectTitle = "SelectTitle";
        public RaisingStudio.Data.Expressions.ColumnExpression SelectTitle { get { return _SelectTitle; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _SelectFilename = "SelectFilename";
        public RaisingStudio.Data.Expressions.ColumnExpression SelectFilename { get { return _SelectFilename; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Edit = "Edit";
        public RaisingStudio.Data.Expressions.ColumnExpression Edit { get { return _Edit; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _owshiddenversion = "owshiddenversion";
        public RaisingStudio.Data.Expressions.ColumnExpression owshiddenversion { get { return _owshiddenversion; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __UIVersion = "_UIVersion";
        public RaisingStudio.Data.Expressions.ColumnExpression _UIVersion { get { return __UIVersion; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression __UIVersionString = "_UIVersionString";
        public RaisingStudio.Data.Expressions.ColumnExpression _UIVersionString { get { return __UIVersionString; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _InstanceID = "InstanceID";
        public RaisingStudio.Data.Expressions.ColumnExpression InstanceID { get { return _InstanceID; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _Order = "Order";
        public RaisingStudio.Data.Expressions.ColumnExpression Order { get { return _Order; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _GUID = "GUID";
        public RaisingStudio.Data.Expressions.ColumnExpression GUID { get { return _GUID; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _WorkflowVersion = "WorkflowVersion";
        public RaisingStudio.Data.Expressions.ColumnExpression WorkflowVersion { get { return _WorkflowVersion; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _WorkflowInstanceID = "WorkflowInstanceID";
        public RaisingStudio.Data.Expressions.ColumnExpression WorkflowInstanceID { get { return _WorkflowInstanceID; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _ParentVersionString = "ParentVersionString";
        public RaisingStudio.Data.Expressions.ColumnExpression ParentVersionString { get { return _ParentVersionString; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _ParentLeafName = "ParentLeafName";
        public RaisingStudio.Data.Expressions.ColumnExpression ParentLeafName { get { return _ParentLeafName; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _MasterPageDescription = "MasterPageDescription";
        public RaisingStudio.Data.Expressions.ColumnExpression MasterPageDescription { get { return _MasterPageDescription; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _FilenameMenuNoLink = "FilenameMenuNoLink";
        public RaisingStudio.Data.Expressions.ColumnExpression FilenameMenuNoLink { get { return _FilenameMenuNoLink; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _MasterPageIcon = "MasterPageIcon";
        public RaisingStudio.Data.Expressions.ColumnExpression MasterPageIcon { get { return _MasterPageIcon; } }
        public static readonly RaisingStudio.Data.Expressions.ColumnExpression _FilenameNoLink = "FilenameNoLink";
        public RaisingStudio.Data.Expressions.ColumnExpression FilenameNoLink { get { return _FilenameNoLink; } }

		#endregion

        public static implicit operator RaisingStudio.Data.Expressions.ConditionExpression(_MasterPageGallery MasterPageGallery)
        {
            return new RaisingStudio.Data.Expressions.ConditionExpression();
        }

        public RaisingStudio.Data.Expressions.ConditionExpression OrderBy(RaisingStudio.Data.Expressions.ColumnExpression columnExpression)
        {
             RaisingStudio.Data.Expressions.ConditionExpression conditionExpression = this;
             return conditionExpression.OrderBy(columnExpression);
        }

        public RaisingStudio.Data.Expressions.ConditionExpression OrderBy(RaisingStudio.Data.Expressions.ColumnExpression columnExpression, RaisingStudio.Data.Expressions.SortingDirection sortingDirection)
        {
            RaisingStudio.Data.Expressions.ConditionExpression conditionExpression = this;
            return conditionExpression.OrderBy(columnExpression, sortingDirection);
        }

        public RaisingStudio.Data.Expressions.ConditionExpression Where(RaisingStudio.Data.Expressions.ExpressionElement expressionElement)
        {
            RaisingStudio.Data.Expressions.ConditionExpression conditionExpression = this;
            return conditionExpression.Where(expressionElement);
        }

        public static implicit operator RaisingStudio.Data.Expressions.ColumnExpressionCollection(_MasterPageGallery MasterPageGallery)
        {
            return new RaisingStudio.Data.Expressions.ColumnExpressionCollection(MasterPageGallery);
        }

        public static implicit operator RaisingStudio.Data.Expressions.ColumnExpression[](_MasterPageGallery MasterPageGallery)
        {
            return new RaisingStudio.Data.Expressions.ColumnExpression[]
                        {                            
                            MasterPageGallery.ID,
                            MasterPageGallery.ContentTypeId,
                            MasterPageGallery.ContentType,
                            MasterPageGallery.Created,
                            MasterPageGallery.Author,
                            MasterPageGallery.Modified,
                            MasterPageGallery.Editor,
                            MasterPageGallery._HasCopyDestinations,
                            MasterPageGallery._CopySource,
                            MasterPageGallery._ModerationStatus,
                            MasterPageGallery._ModerationComments,
                            MasterPageGallery.FileRef,
                            MasterPageGallery.FileDirRef,
                            MasterPageGallery.Last_x0020_Modified,
                            MasterPageGallery.Created_x0020_Date,
                            MasterPageGallery.File_x0020_Size,
                            MasterPageGallery.FSObjType,
                            MasterPageGallery.PermMask,
                            MasterPageGallery.CheckedOutUserId,
                            MasterPageGallery.IsCheckedoutToLocal,
                            MasterPageGallery.CheckoutUser,
                            MasterPageGallery.FileLeafRef,
                            MasterPageGallery.UniqueId,
                            MasterPageGallery.ProgId,
                            MasterPageGallery.ScopeId,
                            MasterPageGallery.VirusStatus,
                            MasterPageGallery.CheckedOutTitle,
                            MasterPageGallery._CheckinComment,
                            MasterPageGallery.LinkCheckedOutTitle,
                            MasterPageGallery.Modified_x0020_By,
                            MasterPageGallery.Created_x0020_By,
                            MasterPageGallery.File_x0020_Type,
                            MasterPageGallery.HTML_x0020_File_x0020_Type,
                            MasterPageGallery._SourceUrl,
                            MasterPageGallery._SharedFileIndex,
                            MasterPageGallery._EditMenuTableStart,
                            MasterPageGallery._EditMenuTableEnd,
                            MasterPageGallery.LinkFilenameNoMenu,
                            MasterPageGallery.LinkFilename,
                            MasterPageGallery.DocIcon,
                            MasterPageGallery.ServerUrl,
                            MasterPageGallery.EncodedAbsUrl,
                            MasterPageGallery.BaseName,
                            MasterPageGallery.FileSizeDisplay,
                            MasterPageGallery.MetaInfo,
                            MasterPageGallery._Level,
                            MasterPageGallery._IsCurrentVersion,
                            MasterPageGallery.SelectTitle,
                            MasterPageGallery.SelectFilename,
                            MasterPageGallery.Edit,
                            MasterPageGallery.owshiddenversion,
                            MasterPageGallery._UIVersion,
                            MasterPageGallery._UIVersionString,
                            MasterPageGallery.InstanceID,
                            MasterPageGallery.Order,
                            MasterPageGallery.GUID,
                            MasterPageGallery.WorkflowVersion,
                            MasterPageGallery.WorkflowInstanceID,
                            MasterPageGallery.ParentVersionString,
                            MasterPageGallery.ParentLeafName,
                            MasterPageGallery.MasterPageDescription,
                            MasterPageGallery.FilenameMenuNoLink,
                            MasterPageGallery.MasterPageIcon,
                            MasterPageGallery.FilenameNoLink,
                        };
        }

        public RaisingStudio.Data.Expressions.ColumnExpressionCollection Except(params RaisingStudio.Data.Expressions.ColumnExpression[] columns)
        {
            RaisingStudio.Data.Expressions.ColumnExpressionCollection columnExpressionCollection = this;
            return columnExpressionCollection.Except(columns);
        }

    
        public static implicit operator RaisingStudio.Data.Expressions.QueryExpression<_MasterPageGallery>(_MasterPageGallery MasterPageGallery)
        {
            return new RaisingStudio.Data.Expressions.QueryExpression<_MasterPageGallery>(MasterPageGallery);
        }


        #region IQueryExpression<_MasterPageGallery> 成员

        _MasterPageGallery RaisingStudio.Data.Expressions.IQueryExpression<_MasterPageGallery>.Value
        {
            get { return MasterPageGallery._; }
        }

        #endregion

        #region IQueryExpression 成员

        RaisingStudio.Data.Expressions.TableExpression RaisingStudio.Data.Expressions.IQueryExpression.Table
        {
            get { return this; }
        }

        RaisingStudio.Data.Expressions.ConditionExpression RaisingStudio.Data.Expressions.IQueryExpression.Condition
        {
            get { return this; }
        }

        RaisingStudio.Data.Expressions.ColumnExpressionCollection RaisingStudio.Data.Expressions.IQueryExpression.Columns
        {
            get { return null; }
        }

        #endregion
    }

    partial class MasterPageGallery
    {
        #region Members
        public static readonly _MasterPageGallery _ = new _MasterPageGallery();
		#endregion
    }
}
